<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org" xmlns:sa="http://www.thymeleaf.org/extras/sa-token">

<head th:replace="index::head">
</head>

<body>
    <!-- 导航栏 -->
    <ul class="layui-nav" th:replace="index::nav">

    </ul>
    <div class="layui-container">
        <div class="layui-row">
            <div class="layui-col-xs2" th:replace="index::snav">
            </div>
            <div class="layui-col-xs10">
                <table class="layui-table" lay-even lay-skin="line" lay-size="lg">
                    <colgroup>
                        <col width="150">
                        <col>
                    </colgroup>
                    <thead>
                        <tr>
                            <th>订单号</th>
                            <th>下单日期</th>
                            <th>状态</th>
                            <th>金额</th>
                            <!-- <th>操作</th> -->
                        </tr>
                    </thead>
                    <tbody>
                        <tr th:each="c:${orders}">
                            <!-- <td>
                                <input type="checkbox" name="like[read]" title="阅读" checked>
                            </td> -->
                            <td th:text="${c.id}">贤心</td>
                            <td th:text="${c.orderDate}">贤心</td>
                            <td th:text="${c.status}">贤心</td>
                            <td th:text="${c.totalAmount}">3</td>
                            <!-- <td>
                                <button type="button" class="layui-btn layui-btn-danger"
                                th:onclick="'del('+${c.id}+')'">移除</button>
                            </td> -->
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
    </div>

</body>
<!-- <script>
        function del(id) {
        layer.confirm('确定要删除这条吗？', {
            btn: ['删除', '取消']
        }, function () {
            $.get("/cart/remove/" + id, function (data) {
                if (data.code === 200) {
                    layer.msg("删除成功");
                    setTimeout(() => {
                        window.location.reload();
                    }, 1200);
                }
            })
        }, function () {

        });
    }
</script> -->
</html>